<%@ page import="edu.uow.devdocs.Checklist" %>



<fieldset class="fieldcontain ${hasErrors(bean: checklistInstance, field: 'description', 'error')} ">
	<label for="description"><g:message code="checklist.description.label" default="Description" /></label>
	<g:textField name="description" value="${checklistInstance?.description}" class="form-text" />
</fieldset>

<fieldset class="fieldcontain ${hasErrors(bean: checklistInstance, field: 'renderHtmlFlag', 'error')} ">
	<label for="renderHtmlFlag"><g:message code="checklist.renderHtmlFlag.label" default="Render Html Flag" /></label>
	<g:checkBox name="renderHtmlFlag" value="${checklistInstance?.renderHtmlFlag}" />
</fieldset>

	<g:if test="${checklistInstance?.renderHtmlFlag }">
		<ckeditor:config var="toolbar_Mytoolbar">
		[
		    [ 'Cut','Copy','Paste','PasteText','PasteFromWord','-','Undo','Redo' ],
		    [ 'Find','Replace','-','SelectAll','-','SpellChecker', 'Scayt' ],
		    [ 'Form', 'Checkbox', 'Radio', 'TextField', 'Textarea', 'Select', 'Button', 'ImageButton', 'HiddenField' ],
		    [ 'Bold','Italic','Underline','Strike','Subscript','Superscript','-','RemoveFormat' ],
		    [ 'NumberedList','BulletedList','-','Outdent','Indent','-','Blockquote','CreateDiv','-','JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock','-','BidiLtr','BidiRtl' ],
		    [ 'Table','HorizontalRule','Smiley','SpecialChar','PageBreak' ],
		    [ 'Styles','Format','Font','FontSize' ],
		    [ 'TextColor','BGColor' ],
		    [ 'Maximize', 'ShowBlocks','-','About' ]
		    
		]
		</ckeditor:config>
		<script>if (CKEDITOR.instances['checklist']) {delete CKEDITOR.instances['checklist']}</script>
		<ckeditor:editor name="checklist" toolbar="Mytoolbar">
		<%= checklistInstance?.checklist %>
		</ckeditor:editor>
	</g:if>
	<g:if test="${! checklistInstance?.renderHtmlFlag }">
	<fieldset>
		<label for="checklistContent">Comments</label>
		<g:textArea name="checklistContent">${checklistInstance?.checklist}</g:textArea>
	</fieldset>
	</g:if>
